package afk.biglog;

import java.util.logging.*;

import afk.biglog.gui.*;
import afk.lib.*;

public class BigLogViewStarter
{

	public static void main(final String[] args)
	{
		prepareGlobalLog();

		// showSplash();
		final MainViewAdapter logView = new MainViewAdapter();
		final BigLogViewApplication app = new BigLogViewApplication(logView);
		logView.register(app);
		app.init();
		logView.init();
		logView.show();
		// hideSplash();
	}

	private static void prepareGlobalLog()
	{
		final Logger log = Logger.getLogger(BigLogViewStarter.class.getPackage().getName());
		log.setUseParentHandlers(true);
		log.setLevel(Level.INFO);
		final ConsoleHandler consoleHandler = new ConsoleHandler();
		consoleHandler.setFormatter(new AfkFormatter());
		log.addHandler(consoleHandler);
		log.setUseParentHandlers(false);
	}

}
